﻿using Architecture.Domain;
using Architecture.Repository.InterfaceRabbit;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Architecture.Repository.ImplRabbit
{
    /// <summary>
    /// 溯源表仓储
    /// </summary>
    public class TraceabilityRepository : BaseRepository<Traceability>, ITraceabilityRepository
    {
        public TraceabilityRepository(EFCoreContext context) : base(context)
        {
        }
        /// <summary>
        /// 添加
        /// </summary>
        /// <param name="entity"></param>
        /// <returns></returns>
        public async Task<int> AddAsync(Traceability entity)
        {
            return await base.AddAsync(entity);
        }
        /// <summary>
        /// 修改
        /// </summary>
        /// <param name="entity"></param>
        /// <returns></returns>
        public async Task<int> UpdateAsync(Traceability entity)
        {
            return await base.UpdateAsync(entity);
        }
        /// <summary>
        /// 显示查询
        /// </summary>
        /// <returns></returns>
        public async Task<List<Traceability>> GetAllAsync()
        {
            return await base.GetAllAsync();
        }
        /// <summary>
        /// 反填
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        public async Task<Traceability> GetAsync(int id)
        {
            return await base.GetAsync(id);
        }
        /// <summary>
        /// 真-删除
        /// </summary>
        /// <param name="entity"></param>
        /// <returns></returns>
        public async Task<int> isDelte(int entity)
        {
            return await base.isDelte(entity);
        }
    }
}
